﻿using NExt.Core.Model.Base;

namespace NExt
{
    public class Window : Window<WindowEvents>
    {
    }

    public abstract class Window<TEvents>: Panel<TEvents>
        where TEvents : WindowEvents, new()
    {
        public string animateTarget { get; set; }
        public string closeAction { get; set; }
        public bool? constrain { get; set; }
        public bool? constrainHeader { get; set; }
        public object defaultButton { get; set; } //TODO
        public bool? expandOnShow { get; set; }
        public WindowGroup manager{ get; set; }
        public bool? maximizable { get; set; }
        public bool? maximized { get; set; }
        public int? minHeight { get; set; }
        public int? minWidth { get; set; }
        public bool? minimizable { get; set; }
        public bool? modal { get; set; }
        public IScript onEsc { get; set; }
        public bool? plain { get; set; }
        public bool? resizable { get; set; }
        public string resizeHandles { get; set; }
    }

    public class WindowEvents : PanelEvents
    {
        public IScript maximize { get; set; }
        public IScript minimize { get; set; }
        public IScript restore { get; set; }
    }
}
